From: cl349@freefall.cl.cam.ac.uk Date: Fri, 24 Sep 2004 14:24:33 +0000 (+0000) Subject: bitkeeper revision 1.1159.83.9 (41542e212WOTlwxlL6GYzK1_CRdC4g) X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~17400^2~573^2 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/%22bookmarks://%22/%22http:/www.example.com/cgi/%22https:/%22bookmarks:/%22?a=commitdiff_plain;h=1569997010aff99cd5c07c7912ca13f83ae6058a;p=xen.git bitkeeper revision 1.1159.83.9 (41542e212WOTlwxlL6GYzK1_CRdC4g) Fix writable pagetable revalidation check for when a page is made readonly. --- diff --git a/xen/arch/x86/memory.c b/xen/arch/x86/memory.c index e08b75e3c2..8cb0b42366 100644 --- a/xen/arch/x86/memory.c +++ b/xen/arch/x86/memory.c @@ -1644,12 +1644,12 @@ void ptwr_flush(const int which) l1_pgentry_t ol1e, nl1e; nl1e = ptwr_info[cpu].ptinfo[which].page[i]; ol1e = pl1e[i]; - if (likely(l1_pgentry_val(nl1e) == l1_pgentry_val(ol1e))) + if (likely(l1_pgentry_val(ol1e) == l1_pgentry_val(nl1e))) continue; - if (likely(l1_pgentry_val(nl1e) == (l1_pgentry_val(ol1e) | _PAGE_RW))) + if (likely(l1_pgentry_val(ol1e) == (l1_pgentry_val(nl1e) | _PAGE_RW))) { if (likely(readonly_page_from_l1e(nl1e))) { - pl1e[i] = ptwr_info[cpu].ptinfo[which].page[i]; + pl1e[i] = nl1e; continue; } } @@ -1659,7 +1659,7 @@ void ptwr_flush(const int which) MEM_LOG("ptwr: Could not re-validate l1 page\n"); domain_crash(); } - pl1e[i] = ptwr_info[cpu].ptinfo[which].page[i]; + pl1e[i] = nl1e; } unmap_domain_mem(pl1e);